namespace cnVery.bbs.UI.Archiver.XHTML
{
    using System;
    using System.Text.RegularExpressions;
    using System.Web;
    using System.Web.UI;

    public class user_profile : Page
    {
        private void InitializeComponent()
        {
            base.Load += new EventHandler(this.Page_Load);
        }

        protected override void OnInit(EventArgs e)
        {
            this.InitializeComponent();
            base.OnInit(e);
        }

        private void Page_Load(object sender, EventArgs e)
        {
            string str = string.Empty;
            if (base.Request.RawUrl.ToString().ToLower().EndsWith(".aspx"))
            {
                str = base.Request.QueryString["name"];
            }
            else
            {
                str = HttpUtility.UrlDecode(Regex.Replace(base.Request.Url.ToString(), @"^[^\?]+\?name=(.+)$", "$1", RegexOptions.IgnoreCase));
            }
            base.Response.Redirect("../../user_profile.aspx?name=" + str);
        }
    }
}

